|
Neurosis Engine
|
00001 00002 // Neurosis Engine - LP23.com 00003 // Copyright © Luigi Pino. All rights reserved. 00004 00005 /***************************************************************************/ 00006 00007 #ifndef _NEUROSIS_ENGINE_IO_FILE_H_ 00008 #define _NEUROSIS_ENGINE_IO_FILE_H_ 00009 00010 /***************************************************************************/ 00011 00012 //------------------------------------------------ 00013 #define LOG_BLACK 0 00014 #define LOG_RED 1 00015 #define LOG_GREEN 2 00016 #define LOG_BLUE 3 00017 //------------------------------------------------ 00018 00019 /***************************************************************************/ 00020 00021 class CNeurosisIO { 00022 public: 00023 CNeurosisIO(); 00025 ~CNeurosisIO(); 00026 00028 static bool Create_Dummy_File(const char *filename, int byteSize); 00030 static void Log_Append(FILE *pFile, int textColor, bool showDateTime, const char *data, ...); 00032 static void Log_Error(FILE *pFile, int textColor, const char *textInfo); 00034 static FILE* Log_Initialize(const char *filename, bool newFile); 00036 static void Registry_Delete(HKEY key, char *subkey, char *name); 00038 static CString Registry_Retrieve(HKEY key, char *subkey, char *name); 00040 static void Registry_Store(HKEY key, char *subkey, char *name, char *data); 00042 static CString Retrieve_Data_INI(const char *filename, const char *section, const char *key, const char *defaultValue, ...); 00045 static CString Retrieve_Data_TXT(const char *filename, const char *token, const char *defaultValue); 00047 static CString Retrieve_Data_URL(const char *urlString, const char *filename); 00049 static CString Retrieve_Extension(CString filename); 00051 static int Retrieve_File_Size(const char *filename); 00053 static int Retrieve_File_Time_Create(const char *filename); 00055 static int Retrieve_File_Time_Modify(const char *filename); 00057 static int Retrieve_Folder_Time_Create(const char *foldername); 00059 static bool Retrieve_String_Position(FILE *pFile, const char *token, bool resetFilePosition = false); 00061 static void Save_Data_INI(const char *filename, const char *section, const char *key, const char *data, ...); 00062 }; 00063 00064 /***************************************************************************/ 00065 #endif
1.7.6.1